Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed shared labels in do loops #43

Open
wants to merge 13 commits into
base: master
Choose a base branch
from

Conversation

bendudson
Copy link
Collaborator

Fixes warnings from grd/grdcomp like

Fortran 2018 deleted feature: Shared DO termination label 2208 at (1)

Fixes warnings from grd/grdcomp like
```
Fortran 2018 deleted feature: Shared DO termination label 2208 at (1)
```
@holm10
Copy link
Collaborator

holm10 commented Jul 25, 2023

This is probably the same error that raises warnings in the other packages as well? E.g. the warnings raised during the automated checks for com/comutil, svr/daspk, svr/nksol, svr/vodpk, svr/daux1, api/fmombal, and api/inelrates. Would it be straightforward to apply the same fix to the other packages too?

@bendudson
Copy link
Collaborator Author

@holm10 Yes I think most of the warnings are related to shared labels on nested DO loops

    do 10 i = 1, n
        do 10 j = 1, m
          blah blah
10

should be replaced by something like

    do i = 1, n
        do j = 1, m
          blah blah
        end do
    end do

I started with grd because it seemed quite straightforward compared to other code. Most fixes should be straightforward, but shared labels can be confusing e.g. issue #44

@holm10
Copy link
Collaborator

holm10 commented Jul 25, 2023

Thanks, @bendudson. I suggest to fix them all in this PR, I could give it a go myself later this week. We'll have to run #44 by @trognlien, I'd say.

@holm10
Copy link
Collaborator

holm10 commented Oct 19, 2023

@bendudson I fixed the simple warnings associated with the DO-loops. Plenty of places that don't raise warnings where the labels could be replaced. Compiler still throws a bunch of errors for comutil: mostly some very nasty logical loops using arithmetic IF statements (and deprecated ASSIGN calls). It'd be nice to fix all of these at some point, but I'm ot sure what it would take to assert that the rewrite is logically equivalent...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants